from django.urls import path, re_path

from . import views
from .views import *

urlpatterns = [
    path('homepage/', homepage, name='homepage'),
    path('404/', not_found, name='not_found'),
    re_path('^main_page/(?P<classify>[\u4e00-\u9fa5a-zA-Z0-9]+)/$', main_page),
    path('record/publish', PublishView.as_view(), name='Publish'),
    path('record/<int:id>/', RecordDetailView.as_view(), name='RecordDetail'),
    path('record/user/', RecordUser.as_view(), name='RecordUser'),
    path('record/user/update/<int:id>', RecordUpdate.as_view(), name='RecordUpdate'),
    path('record/user/delete/<int:id>', RecordDelete.as_view(), name='RecordDelete'),
    path('main/', main, name='main'),
    path('userdetail_put/', UserView.as_view(), name='userdetail_put'),
    path('userdetail/<int:id>/', UserDetailView.as_view(), name='user_detail'),
]
